package collection;

import java.util.HashSet;
import java.util.LinkedHashSet;
import java.util.Set;

public class HashSetDemo {
    public static void main(String[] args) {
        //Set<Point> hs = new LinkedHashSet<>();
        HashSet<Point>hs = new HashSet<>();
        hs.add(new Point(1,2));
        hs.add(new Point(10,20));
        hs.add(new Point(100,200));
        hs.add(new Point(1000,2000));
        hs.add(new Point(10000,20000));
        hs.add(new Point(100000,200000));
        boolean b = hs.add(new Point(1,2));
        System.out.println(b);
        System.out.println(hs);
    }
}
